﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Pages/Site1.Master" AutoEventWireup="true" CodeBehind="rate.aspx.cs" Inherits="ES_Project.Pages.WebForm26" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <link type="text/css" href="js/js/css/ui-lightness/jquery-ui-1.8.10.custom.css" rel="stylesheet" />	
<link type="text/css" href="js/js/css/jquery.timeentry.css" rel="stylesheet" />
  <script type="text/javascript" src="js/js/jquery-1.4.4.min.js"></script>
  <script type="text/javascript" src="js/js/jquery-ui-1.8.10.offset.datepicker.min.js"></script>
  <script type="text/javascript" src="js/js/jquery.datepick-th.js"></script>
  <script type="text/javascript" src="js/js/jquery-ui-timepicker-addon.js"></script>
  <script type="text/javascript" src="js/js/jquery.timeentry.js"></script>
  <script type="text/javascript" src="js/js/jquery.timeentry.min.js"></script>
  <script type="text/javascript" src="js/js/jquery.timeentry.pack.js"></script>
    <style type="text/css">
        

/* Overide css code กำหนดความกว้างของปฏิทินและอื่นๆ */ 
.ui-datepicker{

	width:190px;

	font-family:tahoma;

	font-size:11px;

	text-align:center;

}
/* css for timepicker */
.ui-timepicker-div .ui-widget-header { margin-bottom: 8px; }
.ui-timepicker-div dl { text-align: left; }
.ui-timepicker-div dl dt { height: 25px; margin-bottom: -25px; }
.ui-timepicker-div dl dd { margin: 0 10px 10px 65px; }
.ui-timepicker-div td { font-size: 90%; }
.ui-tpicker-grid-label { background: none; border: none; margin: 0; padding: 0; }
</style>
    <style type="text/css">
        table{font-size:small;
margin-top: 0px;
    color: #000000;
}
TABLE {
	MARGIN-BOTTOM: 0px
}
        .style3
        {
            width: 59px;
        }
        .style4
        {
            width: 1167px;
        }
    .DNNAlignright {
	TEXT-ALIGN: right
}
select,input,button,textarea,button{font:99% arial,helvetica,clean,sans-serif;}
INPUT {
	FONT: 700 small normal normal arial, helvetica, clean, sans-serif; COLOR: #057cc4; MARGIN-LEFT: 0px; MARGIN-RIGHT: 0px;
    text-align: left;
}
SELECT {
	FONT: 700 small normal normal arial, helvetica, clean, sans-serif; COLOR: #057cc4; MARGIN-LEFT: 0px; MARGIN-RIGHT: 0px
}
TEXTAREA {
	FONT: 700 small normal normal arial, helvetica, clean, sans-serif; COLOR: #057cc4; MARGIN-LEFT: 0px; MARGIN-RIGHT: 0px
}
TH {
	FONT-FAMILY: Tahoma, Arial, Helvetica; COLOR: #003366; FONT-SIZE: 12px; VERTICAL-ALIGN: baseline; FONT-WEIGHT: bold
}
        .style15
        {
            width: 100%;
        }
        .style19
        {
            width: 47px;
        }
        .style20
        {
            width: 1167px;
            font-size: small;
        }
        .style35
        {
            width: 1167px;
            font-size: medium;
        }
        .style37
        {
            width: 120px;
            text-align: left;
        }
        .style41
    {
        font-size: small;
        text-align: left;
        width: 103px;
    }
        .style62
        {
            font-size: small;
            font-weight: bold;
            text-align: left;
            width: 83px;
        }
        .style63
        {
            text-align: right;
        }
        .style64
        {
            font-family: Arial, Helvetica, sans-serif;
        }
        .style65
        {
            width: 248px;
        }
        .style66
        {
            font-size: small;
            text-align: left;
            width: 178px;
        }
      </style>
    
  <SCRIPT type=text/javascript>
      function getFormattedDate(date) {
          var day = date.getDate();
          var month = date.getMonth() + 1;
          var year = date.getFullYear().toString().slice(2);
          return day + '-' + month + '-' + year;
      }
      function GotoInput2(pagGo) {

          emailwindow = dhtmlmodal.open('EmailBox', 'iframe', pagGo, ' ', 'width=923px,height=545px,center=1,resize=0,scrolling=1')

          emailwindow.onclose = function () {


              return true

          }


      }

      function GotoInput(pagGo) {

          emailwindow = dhtmlmodal.open('EmailBox3', 'iframe', pagGo, ' ', 'width=840px,height=405px,center=1,resize=0,scrolling=1')

          emailwindow.onclose = function () {

              return true

          }
      }

      //-->

				</SCRIPT>
               
                 
                         

        <asp:ScriptManager ID="ScriptManager1" runat="server" EnablePageMethods="true"/>
       
   
 <!--<asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>-->
            <table cellpadding="0" cellspacing="0" class="style2">
                <tr>
                    <td class="style3">
                        &nbsp;</td>
                    <td class="style35">
                        <strong>บันทึกส่วนลด</strong></td>
                    <td class="style19">
                        &nbsp;</td>
                </tr>
                <tr>
                    <td class="style3">
                        &nbsp;</td>
                    <td class="style4">
                        &nbsp;</td>
                    <td class="style19">
                        &nbsp;</td>
                </tr>
                <tr>
                    <td class="style3">
                        &nbsp;</td>
                    <td class="style4">
                        <table cellpadding="0" cellspacing="0" class="style15">
                            <tr>
                                <td class="style63">
                                    <strong>รหัสโรงเรียน :</strong></td>
                                <td>
                                    <asp:TextBox ID="TextBox5" runat="server"></asp:TextBox>
                                </td>
                                <td class="style63">
                                    <strong>ชื่อโรงเรียน :</strong></td>
                                <td>
                                    <asp:TextBox ID="TextBox6" runat="server"></asp:TextBox>
                                </td>
                                <td class="style63">
                                    <strong>สาขา :</strong></td>
                                <td>
                                    <textarea ID="TextArea2" runat="server" cols="20" name="S2" rows="2"></textarea></td>
                                <td class="style63">
                                    <strong>ที่อยู่สาขา :</strong></td>
                                <td>
                                    <textarea ID="TextArea3" runat="server" cols="20" name="S3" rows="2"></textarea></td>
                            </tr>
                            <tr>
                                <td>
                                    &nbsp;</td>
                                <td>
                                    &nbsp;</td>
                                <td>
                                    &nbsp;</td>
                                <td>
                                    &nbsp;</td>
                                <td>
                                    &nbsp;</td>
                                <td>
                                    &nbsp;</td>
                                <td>
                                    &nbsp;</td>
                                <td>
                                    &nbsp;</td>
                            </tr>
                            <tr>
                                <td class="style63">
                                    <span class="style64" 
                                        style="color: rgb(34, 34, 34); font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; background-color: rgba(255, 255, 255, 0.917969); display: inline !important; float: none;">
                                    <strong>เลขประจำตัวผู้เสียภาษี :</strong></span></td>
                                <td>
                                    <asp:TextBox ID="TextBox7" runat="server"></asp:TextBox>
                                </td>
                                <td class="style63">
                                    <strong>ประเภท</strong><b>ส่วนลด :</b></td>
                                <td>
                                    <textarea ID="TextArea1" runat="server" cols="20" name="S1" rows="2"></textarea></td>
                                <td class="style63">
                                    <strong>จำนวนลด:</strong></td>
                                <td>
                                    <strong>
                                    <asp:TextBox ID="TextBox3" runat="server" Width="78px"></asp:TextBox>
                                    %<asp:TextBox ID="TextBox4" runat="server"  style="display:none"></asp:TextBox>
                                    </strong></td>
                                <td class="style63">
                                    &nbsp;</td>
                                <td>
                                    <strong>
                                    &nbsp;</strong></td>
                            </tr>
                        </table>
                    </td>
                    <td class="style19">
                        &nbsp;</td>
                </tr>
                <tr>
                    <td class="style3">
                        &nbsp;</td>
                    <td class="style4">
                        <table cellpadding="0" cellspacing="0" class="style15">
                            <tr>
                                <td class="style66">
                                    &nbsp;</td>
                                <td class="style65">
                                    &nbsp;</td>
                                <td class="style41">
                                    &nbsp;</td>
                                <td class="style37">
                                    &nbsp;</td>
                                <td class="style62">
                                    &nbsp;</td>
                                <td>
                                    &nbsp;</td>
                                <td>
                                    &nbsp;</td>
                            </tr>
                            <tr>
                                <td class="style66">
                                    &nbsp;</td>
                                <td class="style65">
                                    &nbsp;&nbsp;<asp:Button ID="Button1" runat="server" onclick="Button1_Click" 
                                        Text="บันทึก" />
                                    &nbsp;<asp:Button ID="Button5" runat="server" onclick="Button5_Click" Text="แก้ไข" 
                                        Width="60px" />
                                    &nbsp;<asp:Button ID="Button2" runat="server" Text="เคลียร์" 
                                        onclick="Button2_Click" />
                                </td>
                                <td class="style41">
                                    &nbsp;</td>
                                <td class="style37">
                                    &nbsp;</td>
                                <td class="style62">
                                    &nbsp;</td>
                                <td>
                                    &nbsp;</td>
                                <td>
                                    &nbsp;</td>
                            </tr>
                        </table>
                    </td>
                    <td class="style19">
                        &nbsp;</td>
                </tr>
                <tr>
                    <td class="style3">
                        &nbsp;</td>
                    <td class="style20">
                        &nbsp;</td>
                    <td class="style19">
                        &nbsp;</td>
                </tr>
                <tr>
                    <td class="style3">
                        &nbsp;</td>
                    <td class="style4">
                        <asp:GridView ID="GridView2" runat="server" Width="100%"   
                            AutoGenerateColumns="False" border="1" CellPadding="4" ForeColor="#333333"  
                            GridLines="None" onrowdeleting="GridView2_RowDeleting" 
                            onselectedindexchanging="GridView2_SelectedIndexChanging" 
                            DataKeyNames="id_Discount" onrowdatabound="GridView2_RowDataBound">
                            <AlternatingRowStyle BackColor="White" />
                            <Columns>
                            <asp:TemplateField ItemStyle-HorizontalAlign="Center">
                                              <HeaderTemplate>
                                                  ลำดับ
                                              </HeaderTemplate>
                                              <ItemTemplate>
                                                  <%#Container.DataItemIndex+1 %>
                                              </ItemTemplate>
                                              <ItemStyle HorizontalAlign="Center" />
                                          </asp:TemplateField>
                                            <asp:TemplateField HeaderText="โรงเรียน">
                                    <ItemTemplate>
                                        <asp:Label ID="Label4" runat="server" Text='<%# Eval("Code_school")+" "+Eval("Name_school") %>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="สาขา">
                                    <ItemTemplate>
                                        <asp:Label ID="Label5" runat="server" Text ='<%# Eval("Branch") %>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="ที่อยู่">
                                    <ItemTemplate>
                                        <asp:Label ID="Label6" runat="server" Text ='<%# Eval("Address") %>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="เลขประจำตัวผู้เสียภาษี">
                                    <ItemTemplate>
                                        <asp:Label ID="Label7" runat="server" Text ='<%# Eval("Iden_number") %>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="ส่วนลด">
                                    <ItemTemplate>
                                        <asp:Label ID="Label1" runat="server" Text ='<%# Eval("Name_Discount") %>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                <asp:TemplateField HeaderText="จำนวนส่วนลด(%)">
                                    <ItemTemplate>
                                        <asp:Label ID="Label2" runat="server" Text ='<%# Eval("Num_Discount") %>'></asp:Label>
                                    </ItemTemplate>
                                </asp:TemplateField>
                                 <asp:TemplateField HeaderText="id" Visible="False">
                                     <ItemTemplate>
                                         <asp:Label ID="Label3" runat="server" Text ='<%# Eval("id_Discount") %>'></asp:Label>
                                     </ItemTemplate>
                                </asp:TemplateField>
                                 <asp:CommandField ButtonType="Image" HeaderText="แก้ไข" 
                                SelectImageUrl="~/Pages/images/icon_15.gif" SelectText="" 
                                ShowSelectButton="True" />
                                 <asp:CommandField ButtonType="Image" HeaderText="ลบ" 
                                              ItemStyle-HorizontalAlign="Center" 
                                              SelectImageUrl="~/Pages/images/icon_del.gif"  
                                    ShowDeleteButton="True" DeleteImageUrl="~/Pages/images/icon_del.gif" 
                                    DeleteText="" >
                                              <ItemStyle HorizontalAlign="Center" />
                                          </asp:CommandField>
                              
                            </Columns>
                            <EditRowStyle BackColor="#2461BF" />
                            <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                            <HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                            <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
                            <RowStyle BackColor="#EFF3FB" />
                            <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
                            <SortedAscendingCellStyle BackColor="#F5F7FB" />
                            <SortedAscendingHeaderStyle BackColor="#6D95E1" />
                            <SortedDescendingCellStyle BackColor="#E9EBEF" />
                            <SortedDescendingHeaderStyle BackColor="#4870BE" />
                        </asp:GridView>
                    </td>
                    <td class="style19">
                        &nbsp;</td>
                </tr>
                <tr>
                    <td class="style3">
                        &nbsp;</td>
                    <td class="style4">
                        &nbsp;</td>
                    <td class="style19">
                        &nbsp;</td>
                </tr>
                <tr>
                    <td class="style3">
                        &nbsp;</td>
                    <td class="style4">
                        &nbsp;</td>
                    <td class="style19">
                        &nbsp;</td>
                </tr>
                <tr>
                    <td class="style3">
                        &nbsp;</td>
                    <td class="style4">
                        &nbsp;</td>
                    <td class="style19">
                        &nbsp;</td>
                </tr>
                <tr>
                    <td class="style3">
                        &nbsp;</td>
                    <td class="style4">
                        &nbsp;</td>
                    <td class="style19">
                        &nbsp;</td>
                </tr>
            </table>
   <!--    </ContentTemplate>
    </asp:UpdatePanel>-->
     <br />
   
</asp:Content>